import React, { useState } from 'react'

export default function App() {
    const [state, setState] = useState(true)
    return (
        <div>
            <ul>
                {/* 前面条件成立返回后面的，前面不成立返回false */}
                {/* <div className={`nav-item ${type === type.item && 'active'}`}></div> */}

            </ul>
            <button onClick={() => { setState(!state) }}>点击切换</button>
        </div>
    )
}

